<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<html>
<head>
    <title>学生信息展示页</title>
</head>
<body>


<%--
    EL表达式  ${}   从小范围到大范围依次获取
    jstl 标签    for  if
--%>

<table border="1px" cellspacing="0" width="100%">
    <tr>
        <th>学号</th>
        <th>姓名</th>
        <th>年龄</th>
        <th>生日</th>
    </tr>
<%--遍历数据--%>
<c:forEach items="${sessionScope.students}" var="student">
    <tr>
        <td>${student.stuNo}</td>
        <td>${student.stuName}</td>
        <td>${student.age}</td>
        <td>
               <fmt:formatDate value="${student.birth}" pattern="yyyy-MM-dd"></fmt:formatDate>
        </td>
    </tr>
</c:forEach>

</table>




</body>
</html>
